// This file was created by Filewrap 1.1
// Little endian mode
// DO NOT EDIT

#include "../PVRTMemoryFileSystem.h"

// using 32 bit to guarantee alignment.
#ifndef A32BIT
 #define A32BIT static const unsigned int
#endif

// ******** Start: VertShader.vsh ********

// File data
static const char _VertShader_vsh[] = 
	"attribute highp vec4  inVertex;\r\n"
	"attribute highp vec3  inNormal;\r\n"
	"attribute highp vec2  inTexCoord;\r\n"
	"\r\n"
	"uniform highp mat4   MVPMatrix;\r\n"
	"uniform highp vec3   EyePosition;\r\n"
	"uniform highp float  RIRSquare;\r\n"
	"\r\n"
	"varying mediump vec2   ReflectCoord;\r\n"
	"varying mediump vec2   TexCoord;\r\n"
	"varying lowp    float  ReflectRatio;\r\n"
	"\r\n"
	"void main()\r\n"
	"{\r\n"
	"\t// Transform position\r\n"
	"\tgl_Position = MVPMatrix * inVertex;\r\n"
	"\t\r\n"
	"\t// Calculate direction from vertex to eye (model space)\r\n"
	"\thighp vec3 eyeDir = normalize(EyePosition - inVertex.xyz);\r\n"
	"\t\r\n"
	"\t// The reflection intensity depends on the angle between eye direction and\r\n"
	"\t// surface normal.\r\n"
	"\t// The relative index of refraction (RIR) is a material parameter\r\n"
	"\thighp float c = abs(dot(eyeDir, inNormal));\r\n"
	"\thighp float g = sqrt(RIRSquare + c * c - 1.0);\r\n"
	"\thighp float f1 = (g - c) / (g + c);\r\n"
	"\thighp float f2 = (c * (g + c) - 1.0) / (c * (g - c) + 1.0);\r\n"
	"\tReflectRatio = 0.5 * f1 * f1 * (1.0 + f2 * f2);\r\n"
	"\t\r\n"
	"\t// map reflection vector to 2D\r\n"
	"\tReflectCoord = normalize(reflect(eyeDir, inNormal)).xy * 0.5;\r\n"
	"\t\r\n"
	"\tTexCoord = inTexCoord;\r\n"
	"}\r\n";

// Register VertShader.vsh in memory file system at application startup time
static CPVRTMemoryFileSystem RegisterFile_VertShader_vsh("VertShader.vsh", _VertShader_vsh, 1063);

// ******** End: VertShader.vsh ********

// This file was created by Filewrap 1.1
// Little endian mode
// DO NOT EDIT

#include "../PVRTMemoryFileSystem.h"

// using 32 bit to guarantee alignment.
#ifndef A32BIT
 #define A32BIT static const unsigned int
#endif

// ******** Start: VertShader.vsc ********

// File data
A32BIT _VertShader_vsc[] = {
0x10fab438,0xcb32f463,0x30050100,0x2501,0xd363e337,0x2000000,0x20000000,0xd0040000,0x0,0x4000000,0x0,0x39000000,0x20202,0x0,0x2020000,0x1,0x0,0x24030000,0x55535020,0x20,0x318,0x1,0x1,0x0,0x204,0x80,0x2,0x7d,0x0,0x8,0x0,0xffffffff,0x0,0x122000a,0xffff,0x3000a,0x0,0x0,0x14,0x0,0x0,0x0,0x0,0xfffc,0x0,0x0,0x0,0xffff0003,0xffffffff,0x140000,0x80000a,0x1,0x0,0x10001,0x1,0x20001,0x2,0x30001,0x3,0x40001,0x4,0x50001,0x5,0x60001,
0x6,0x70001,0x7,0x80001,0x8,0x90001,0x9,0xa0001,0xa,0xb0001,0xb,0xc0001,0xc,0xd0001,0xd,0xe0001,0xe,0xf0001,0xf,0x100001,0x10,0x110001,0x11,0x120001,0x12,0x130001,0x13,0x37f,0xffffffff,0xffffffff,0x0,0x0,0x4,0x20003,0x80000,0x80010002,0x80018001,0x8001,0x0,0x0,0x0,0x0,0x0,0x1a1a0000,0x10847040,0x5a1b0082,0x10857060,0x9a1c0082,0x10847000,0x81830082,0x140250e0,0x70080,0x100220e0,0x3800080,0x12008020,0xb00880,0x10001000,0x4000081,0x1001a0c0,0x228a1,0x20000,0x80000002,0x80048001,0x8004,
0x0,0x40000,0x4040000,0x1,0x50bfa10,0x3205f000,0x210a8,0x1f0000,0x80010002,0x80008001,0x8000,0x0,0x50000,0x10001,0x10001,0x10001,0x10001,0x10001,0x10001,0x10001,0x10001,0x10001,0x1,0x10001,0x10001,0x0,0x0,0x0,0x1010000,0xfa100000,0xf020060d,0x38980605,0xf0004811,0x38820606,0xf0008a15,0x38820606,0xf040cc19,0x38a20205,0x10604103,0x38980601,0xa0014200,0x38a0c006,0xa0600300,0x801002,0xb000c19d,0x801146,0x51001a34,0x83100e,0x80000400,0x8801202,0x80400000,0x8801002,0x5000c230,0x831006,0x80200300,0x801086,0xa0000205,0x38820686,0xf01f0081,0x831402,0xa1204080,0x801006,0x80200480,0x8801202,
0xa0004080,0x3888c606,0x509f0730,0xa31001,0xa0008183,0x38a30676,0xc0000080,0x8821002,0xd0400030,0x831006,0xd020c0b4,0x83110e,0xd000c034,0x831106,0x80000000,0x8801002,0x906000b0,0x811006,0x50008730,0x831006,0x90200130,0x811006,0x9000c1b4,0x811006,0x91004030,0x811005,0x6,0x1800,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x803f0000,0x3f0000,0x400000,0x0,0xa000000,0x505f6c67,0x7469736f,0x6e6f69,0x5050100,0x1000003,0x10000,0xf000400,0x564d0000,0x74614d50,0x786972,0x3160000,0x1000003,
0x10000,0xffff1000,0x6e690000,0x74726556,0x7865,0x3040500,0x10000,0x100,0xf0004,0x65794500,0x69736f50,0x6e6f6974,0x4000000,0x303,0x1000001,0x31000,0x69000007,0x726f4e6e,0x6c616d,0x4040000,0x1000003,0x10000,0x7000404,0x49520000,0x75715352,0x657261,0x3020000,0x1000003,0x10000,0x1000113,0x65520000,0x63656c66,0x74615274,0x6f69,0x1050200,0x10000,0x8000100,0x10001,0x66655200,0x7463656c,0x726f6f43,0x64,0x20503,0x100,0x2000001,0x300,0x43786554,0x64726f6f,0x3000000,0x205,0x1000001,0x20400,0x69000003,0x7865546e,0x726f6f43,0x64,0x30403,0x100,0x4080001,0x300,0x0,
};

// Register VertShader.vsc in memory file system at application startup time
static CPVRTMemoryFileSystem RegisterFile_VertShader_vsc("VertShader.vsc", _VertShader_vsc, 1264);

// ******** End: VertShader.vsc ********

